<template>
	<uni-popup ref="popup" type="center" :mask-click="false">
		<view class="popup-layout">
			<view class="title">发现新版本</view>
			<view class="confirm-btn" @click="updateNow">立即更新</view>
			<view style="height: 40rpx;"></view>
		</view>
	</uni-popup>
</template>

<script>
	export default {
		data() {
			return {
				
			}
		},
		methods: {
			//显示弹窗
			show() {
				this.$refs.popup.open()
			},

			//关闭
			close() {
				this.$refs.popup.close()
			},
			
			//立即更新
			updateNow(){
				let urlPath =
					`https://download.zhujiao.xn--fiqs8s/`
				// #ifdef APP-PLUS
				plus.runtime.openURL(urlPath);
				// #endif
			}
		}
	}
</script>

<style scoped lang="less">
	.popup-layout {
		width: 500rpx;
		border-radius: 16rpx;
		background: #FFFFFF;
		display: flex;
		flex-direction: column;
		align-items: center;
	}
	.title{
		font-size: 30rpx;
		color: #000000;
		font-weight: 400rpx;
		margin-top: 50rpx;
	}
	.confirm-btn {
		width: 380rpx;
		height: 90rpx;
		line-height: 90rpx;
		text-align: center;
		border-radius: 66rpx;
		background: #01CBFF;
		font-size: 28rpx;
		color: #FFFFFF;
		font-weight: 500;
		margin-top: 70rpx;
		display: flex;
		align-items: center;
		justify-content: center;
	}
	
</style>
